import type { ChatMessage } from '@/types'

export async function initOpenAI(apiKey: string) {
  return await window.electronAPI.initOpenAI(apiKey)
}

export async function sendMessage(message: string, context: ChatMessage[]) {
  return await window.electronAPI.sendMessage(message, context)
}

export async function speechToText(audioData: Buffer) {
  return await window.electronAPI.speechToText(audioData)
} 